﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Log4netTestApp
{
    public class LogHelper
    {
        public static void ErrorLog(Type t, Exception ex)
        {
            log4net.ILog log = log4net.LogManager.GetLogger(t);
            log.Error("错误信息", ex);
        }

        public static void ErrorLog(Type t, string msg)
        {
            log4net.ILog log = log4net.LogManager.GetLogger(t);
            log.Error(msg);
        }

        public static void InfoLog(Type t, string msg)
        {
            log4net.ILog log = log4net.LogManager.GetLogger(t);
            log.Info(msg);
        }

    }
}
